package com.stagewebserver.webserver.service;

import com.stagecommon.common.pojo.Likes;
import org.springframework.data.redis.core.Cursor;

import java.util.List;
import java.util.Map;

public interface RedisService {

    void saveLikeToRedis(Long objId, Long userId, Byte type);
    void unlikeFromRedis(Long objId, Long userId, Byte type);
    void deleteFromRedis(Long objId, Long userId, Byte type);
    Long incrementLikeCount(Long objId, Long userId, Byte type);
    void decrementLikedCount(Long objId, Long userId, Byte type);
    List<Likes> getLikeDataFromRedis();
    Cursor<Map.Entry<Object, Object>> getLikedCountFromRedis();
    int getOneInfoCount(Long objId, Byte type);
    void saveInfoFromDb2Re(Byte type);

}
